package com.hlm.service.impl;

import com.hlm.dao.UserDao;
import com.hlm.domain.Home;
import com.hlm.domain.User;
import com.hlm.domain.UserHome;
import com.hlm.service.HlmUserService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;
@Service
public class HlmUserServiceImpl implements HlmUserService {
    @Resource
    private UserDao userDao;
    //添加客户
    @Override
    public int insertUser(User user) {
        int nums = userDao.insertUser(user);
        return nums;
    }
// 实现客户入住
    @Override
    public int insertUserHome(UserHome userHome) {
        int nums = userDao.insertUserHome(userHome);
        return nums;
    }

    @Override
    public int updateHome(Integer kefangbianhao,String shiyongzhuangtai) {
        int nums = userDao.updateHome(kefangbianhao,shiyongzhuangtai);
        return nums;
    }


    //添加房间类
    @Override
    public int insertHome(Home home) {
        int nums = userDao.insertHome(home);
        return nums;
    }

    //查客户
    @Override
    public List<User> selectUser() {
        return null;
    }
    //查房间
    @Override
    public List<Home> selectHome() {
        return userDao.selectHome();
    }
    //查入住信息表
    @Override
    public List<User> selectUserHome() {
        return null;
    }
}
